/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */

package core;

import java.util.Comparator;

/**
 *
 * @author ddoose
 */
public class IntegerComparator implements Comparator {
    public static final IntegerComparator IDENT = new IntegerComparator();

    public int compare(Object o1, Object o2) {
        int i1 = (Integer)o1;
        int i2 = (Integer)o2;
        
        if (i1 == i2) {
            return 0;
        }
        if (i1 < i2) {
            return -1;
        }
        return 1;
    }
}
